<<<<<<< HEAD


str1 = input("please input string : ")

k = {}

for i in str1:
    k[i] = str1.count(i)
# 打印字典
print(k)

# print(len(k))

# 找出现次数是多少
value = max(k.values())
# print(value)

def get_dict_key(k, value):
    key = list(k.keys())[list(k.values()).index(value)]
    return key

print("出现次数的最多的是",get_dict_key(k,value),"，出现了",value,"次")

=======


str1 = input("please input string : ")

k = {}

for i in str1:
    k[i] = str1.count(i)
# 打印字典
print(k)

# print(len(k))

# 找出现次数是多少
value = max(k.values())
# print(value)

def get_dict_key(k, value):
    key = list(k.keys())[list(k.values()).index(value)]
    return key

print("出现次数的最多的是",get_dict_key(k,value),"，出现了",value,"次")

>>>>>>> 798d51c7a799c2769fd9c8096fbb6ff803da8e57
